<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.org/ui">

	<h:head>
			<title>Cadsatro de Visitante</title>
	</h:head>
	
	<ui:composition template="/layout/commonLayout.xhtml">
		<ui:define name="centro">
		
			<h:form>
			
				<p:panel id="panel" header="Visitante">
		 
		       		<p:messages autoUpdate="true"/>
			
					<h:panelGrid id="gridVisitante" columns="2" cellpadding="5">
						
					   <h:outputLabel for="nome" value="Nome:" style="font-weight:bold"/>
					   <p:inputText id="nome" value="#{visitanteMB.nome}" required="true" label="Nome" />
					
					   <h:outputLabel for="dataNascimento" value="Data Nascimento:" style="font-weight:bold"/>
					   <p:inputMask id="dataNascimento" value="#{visitanteMB.dataNascimento}" label="Data Nascimento" mask="99/99/9999" required="true"  />
					
						<h:outputLabel for="pesoAtual" value="Peso Atual:" style="font-weight:bold"/>                    
				 		<p:inputText id="pesoAtual" value="#{visitanteMB.pesoAtual}" converterMessage="Cannot convert to double." size="3"/>
				 		
				 		<h:outputLabel for="altura" value="Altura:" style="font-weight:bold"/>                    
				 		<p:inputText id="altura" value="#{visitanteMB.altura}" converterMessage="Cannot convert to double." size="3"/>
					   
					   	<h:outputLabel value="Tipo de Pele" style="font-weight:bold" />
						<h:selectOneMenu id="peles" value="#{visitanteMB.tipoPele}"> 
						<f:selectItem itemLabel="Selecione" />  
							<f:selectItems value="#{visitanteMB.tipoPeles}" var="p" itemValue="#{p}" itemLabel="#{p.label}"/>  
						</h:selectOneMenu>
					   
				   	</h:panelGrid>
						
						<p:commandButton value="Enviar" icon="ui-icon-check" actionListener="#{userWizard.save}" />
						
				   	
				   	</p:panel>
				   
			   </h:form>
		   
		   </ui:define>
		   </ui:composition>
	            
	
</html>